home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Language/OS - Multiplatform Resource Library
/
LANGUAGE OS.iso
/
cpp_libs
/
oath.lha
/
oath
/
test
/
bishift.cc
< prev
next >
Wrap
C/C++ Source or Header
|
1991-08-29
|
701b
|
24 lines
#include "oath/bigInteger.h"
#include <iostream.h>
main(int argc, char **argv)
{if(argc != 3)
{cout << argv[0] << " shifts the first number by the second.\n";
cout << "Usage: " << argv[0] << " <bigInteger> <bigInteger>\n";
exit(1);
}
bigIntegerA X = bigIntegerA::make(argv[1]);
bigIntegerA S = bigIntegerA::make(argv[2]);
cout << " X = " << X << endl;
cout << " S = " << S << endl;
cout << "(X <<= S) = " << (X <<= S) << endl;
cout << "(X <<= S) = " << (X <<= S) << endl;
cout << "(X >>= S) = " << (X >>= S) << endl;
cout << "(X >>= S) = " << (X >>= S) << endl;
cout << "(X >>= S) = " << (X >>= S) << endl;
}